function initAddOrder(){
			$("#add").click(
	function(){
	 		addOrder($("#Add_User_ID").val(),$("#Add_Order").val(),$("#Add_Info").val());
			}
		);
				$( "#Add_User_ID" ).autocomplete({
			   minLength: 0,
			selectedIndex:0,
			 source: function (request, response) {            
			 request.page = "1";  
			 request.rows= "100"; 
			 request.User_Name=request.term;
				$.ajax({
					url: "../userHandle/searchUser_Name_ID.jsp?User_Type=3",
					data: request,
					dataType: "json",
					success: function( data, status ) {
					
							response( data );
						
					},
					error: function() {
					
							response( [] );
						
					}
					
				});
			 }
			 });
				
						$("#Sure_Order").click(
	function(){
	 		Sure_Order($("#Sure_Order_User_ID").val(),$("#Sure_Order_Order_ID").val());
			}
		);
			
	}
function Sure_Order(User_ID,Order_ID){
	$.ajax({
   type: "POST",
   async: false,
   dataType: "xml",
   url: "../orderHandle/testConfirm_Order.jsp",
   data: encodeURI("User_ID="+User_ID+"&Order_ID="+Order_ID),
   success: function(xmlResponse){
    //getStart(xmlResponse);
	var statuc=$(xmlResponse).find("statuc").text();	
	if(statuc=="true"){
		alert($(xmlResponse).find('msg').text());
		}else{
		alert($(xmlResponse).find('msg').text());
		}
 	},
		error: function(XMLHttpRequest, textStatus, errorThrown) {
                        alert("status:"+XMLHttpRequest.status+"readyState:"+XMLHttpRequest.readyState+"text:"+XMLHttpRequest.responseText);
                    },
 		});
}
function addOrder(User_ID,order,Info){
	$.ajax({
   type: "POST",
   async: false,
   dataType: "xml",
   url: "../orderHandle/addOrder.jsp",
   data: encodeURI("User_ID="+User_ID+"&order="+order+"&Info="+Info),
   success: function(xmlResponse){
    //getStart(xmlResponse);
	var statuc=$(xmlResponse).find("statuc").text();	
	if(statuc=="true"){
		alert($(xmlResponse).find('msg').text());
		}else{
		alert($(xmlResponse).find('msg').text());
		}
 	},
		error: function(XMLHttpRequest, textStatus, errorThrown) {
                        alert("status:"+XMLHttpRequest.status+"readyState:"+XMLHttpRequest.readyState+"text:"+XMLHttpRequest.responseText);
                    },
 		});
	  }
// JavaScript Document